{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 60,
   "metadata": {
    "collapsed": true,
    "pycharm": {
     "is_executing": false
    }
   },
   "outputs": [],
   "source": [
    "import pandas as pd\n",
    "import numpy as np\n",
    "import datetime\n",
    "import requests\n",
    "import time\n",
    "import random\n",
    "import sys\n",
    "sys.path.insert(0, '..')\n",
    "import d2l"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 61,
   "outputs": [
    {
     "name": "stdout",
     "text": [
      "obs_date           object\nobs_lat           float64\nobs_lon           float64\nobs_source         object\nchl_type           object\nin_situ_chl       float64\nNASA_chlor_a      float64\nTPCA_chl          float64\nchl_ci            float64\nchl_ocx           float64\nCI                float64\nMBR               float64\nmax_blue_rrs      float64\nrrs443            float64\nrrs490            float64\nrrs510            float64\nrrs555            float64\nrrs670            float64\nMEI               float64\nday_radius          int64\npixel_radius        int64\nsat_start_date     object\nsat_end_date       object\nsat_start_lat     float64\nsat_end_lat       float64\nsat_start_lon     float64\nsat_end_lon       float64\nvalidation_set      int64\ncount              object\ndtype: object\n"
     ],
     "output_type": "stream"
    }
   ],
   "source": [
    "chlDataFile = r\"E:\\02Projects\\papers\\chl_model\\data\\seawifs\\seawifs_matchups.csv\"\n",
    "datatypes={\"NASA_chlor_a\":np.float,\"in_situ_chl\":np.float,\"depth_water\":np.float}\n",
    "dt = pd.read_csv(chlDataFile,skiprows=(0),header=(0),parse_dates=True,dtype=datatypes)\n",
    "dt['count'] = None # 新增一列\n",
    "searchedCnt = 1\n",
    "totalCnt = dt.shape[0]\n",
    "print (dt.dtypes)"
   ],
   "metadata": {
    "collapsed": false,
    "pycharm": {
     "name": "#%%\n",
     "is_executing": false
    }
   }
  },
  {
   "cell_type": "code",
   "execution_count": 62,
   "outputs": [
    {
     "data": {
      "text/plain": "     obs_date  obs_lat  obs_lon                      obs_source      chl_type  \\\n0  1997-10-04    9.950  234.590  MBARI: Strutton & Chavez. 2008  Fluorescence   \n1  1997-10-05    5.990  235.070            Valente et al., 2016  Fluorescence   \n2  1997-10-06    5.170  235.170  MBARI: Strutton & Chavez. 2008  Fluorescence   \n3  1997-10-07    3.997  235.072            Valente et al., 2016  Fluorescence   \n4  1997-10-07    1.970  234.960            Valente et al., 2016  Fluorescence   \n\n   in_situ_chl  NASA_chlor_a  TPCA_chl  chl_ci  chl_ocx  ...  day_radius  \\\n0       0.1000        0.1365    0.1371  0.1344   0.1149  ...           2   \n1       0.0815        0.0653    0.0635  0.0541   0.0443  ...           2   \n2       0.0400        0.0578    0.0621  0.0469   0.0811  ...           2   \n3       0.0450        0.0614    0.0659  0.0506   0.0833  ...           2   \n4       0.0610        0.0951    0.0957  0.0856   0.0834  ...           2   \n\n   pixel_radius  sat_start_date  sat_end_date  sat_start_lat  sat_end_lat  \\\n0             1      1997-10-02    1997-10-06          9.875       10.042   \n1             1      1997-10-03    1997-10-07          5.875        6.042   \n2             1      1997-10-04    1997-10-08          5.125        5.292   \n3             1      1997-10-05    1997-10-09          3.875        4.042   \n4             1      1997-10-05    1997-10-09          1.875        2.042   \n\n   sat_start_lon  sat_end_lon  validation_set  count  \n0          9.875       10.042               1   None  \n1          5.875        6.042               1   None  \n2          5.125        5.292               0   None  \n3          3.875        4.042               1   None  \n4          1.875        2.042               1   None  \n\n[5 rows x 29 columns]",
      "text/html": "<div>\n<style scoped>\n    .dataframe tbody tr th:only-of-type {\n        vertical-align: middle;\n    }\n\n    .dataframe tbody tr th {\n        vertical-align: top;\n    }\n\n    .dataframe thead th {\n        text-align: right;\n    }\n</style>\n<table border=\"1\" class=\"dataframe\">\n  <thead>\n    <tr style=\"text-align: right;\">\n      <th></th>\n      <th>obs_date</th>\n      <th>obs_lat</th>\n      <th>obs_lon</th>\n      <th>obs_source</th>\n      <th>chl_type</th>\n      <th>in_situ_chl</th>\n      <th>NASA_chlor_a</th>\n      <th>TPCA_chl</th>\n      <th>chl_ci</th>\n      <th>chl_ocx</th>\n      <th>...</th>\n      <th>day_radius</th>\n      <th>pixel_radius</th>\n      <th>sat_start_date</th>\n      <th>sat_end_date</th>\n      <th>sat_start_lat</th>\n      <th>sat_end_lat</th>\n      <th>sat_start_lon</th>\n      <th>sat_end_lon</th>\n      <th>validation_set</th>\n      <th>count</th>\n    </tr>\n  </thead>\n  <tbody>\n    <tr>\n      <th>0</th>\n      <td>1997-10-04</td>\n      <td>9.950</td>\n      <td>234.590</td>\n      <td>MBARI: Strutton &amp; Chavez. 2008</td>\n      <td>Fluorescence</td>\n      <td>0.1000</td>\n      <td>0.1365</td>\n      <td>0.1371</td>\n      <td>0.1344</td>\n      <td>0.1149</td>\n      <td>...</td>\n      <td>2</td>\n      <td>1</td>\n      <td>1997-10-02</td>\n      <td>1997-10-06</td>\n      <td>9.875</td>\n      <td>10.042</td>\n      <td>9.875</td>\n      <td>10.042</td>\n      <td>1</td>\n      <td>None</td>\n    </tr>\n    <tr>\n      <th>1</th>\n      <td>1997-10-05</td>\n      <td>5.990</td>\n      <td>235.070</td>\n      <td>Valente et al., 2016</td>\n      <td>Fluorescence</td>\n      <td>0.0815</td>\n      <td>0.0653</td>\n      <td>0.0635</td>\n      <td>0.0541</td>\n      <td>0.0443</td>\n      <td>...</td>\n      <td>2</td>\n      <td>1</td>\n      <td>1997-10-03</td>\n      <td>1997-10-07</td>\n      <td>5.875</td>\n      <td>6.042</td>\n      <td>5.875</td>\n      <td>6.042</td>\n      <td>1</td>\n      <td>None</td>\n    </tr>\n    <tr>\n      <th>2</th>\n      <td>1997-10-06</td>\n      <td>5.170</td>\n      <td>235.170</td>\n      <td>MBARI: Strutton &amp; Chavez. 2008</td>\n      <td>Fluorescence</td>\n      <td>0.0400</td>\n      <td>0.0578</td>\n      <td>0.0621</td>\n      <td>0.0469</td>\n      <td>0.0811</td>\n      <td>...</td>\n      <td>2</td>\n      <td>1</td>\n      <td>1997-10-04</td>\n      <td>1997-10-08</td>\n      <td>5.125</td>\n      <td>5.292</td>\n      <td>5.125</td>\n      <td>5.292</td>\n      <td>0</td>\n      <td>None</td>\n    </tr>\n    <tr>\n      <th>3</th>\n      <td>1997-10-07</td>\n      <td>3.997</td>\n      <td>235.072</td>\n      <td>Valente et al., 2016</td>\n      <td>Fluorescence</td>\n      <td>0.0450</td>\n      <td>0.0614</td>\n      <td>0.0659</td>\n      <td>0.0506</td>\n      <td>0.0833</td>\n      <td>...</td>\n      <td>2</td>\n      <td>1</td>\n      <td>1997-10-05</td>\n      <td>1997-10-09</td>\n      <td>3.875</td>\n      <td>4.042</td>\n      <td>3.875</td>\n      <td>4.042</td>\n      <td>1</td>\n      <td>None</td>\n    </tr>\n    <tr>\n      <th>4</th>\n      <td>1997-10-07</td>\n      <td>1.970</td>\n      <td>234.960</td>\n      <td>Valente et al., 2016</td>\n      <td>Fluorescence</td>\n      <td>0.0610</td>\n      <td>0.0951</td>\n      <td>0.0957</td>\n      <td>0.0856</td>\n      <td>0.0834</td>\n      <td>...</td>\n      <td>2</td>\n      <td>1</td>\n      <td>1997-10-05</td>\n      <td>1997-10-09</td>\n      <td>1.875</td>\n      <td>2.042</td>\n      <td>1.875</td>\n      <td>2.042</td>\n      <td>1</td>\n      <td>None</td>\n    </tr>\n  </tbody>\n</table>\n<p>5 rows × 29 columns</p>\n</div>"
     },
     "metadata": {},
     "output_type": "execute_result",
     "execution_count": 62
    }
   ],
   "source": [
    "dt.head()\n"
   ],
   "metadata": {
    "collapsed": false,
    "pycharm": {
     "name": "#%%\n",
     "is_executing": false
    }
   }
  },
  {
   "cell_type": "code",
   "execution_count": 63,
   "outputs": [
    {
     "name": "stdout",
     "text": [
      "['rrs443', 'rrs490', 'rrs510', 'rrs555', 'rrs670']\n"
     ],
     "output_type": "stream"
    },
    {
     "data": {
      "text/plain": "        obs_date  obs_lat  obs_lon                      obs_source  \\\n0     1997-10-04    9.950  234.590  MBARI: Strutton & Chavez. 2008   \n1     1997-10-05    5.990  235.070            Valente et al., 2016   \n2     1997-10-06    5.170  235.170  MBARI: Strutton & Chavez. 2008   \n3     1997-10-07    3.997  235.072            Valente et al., 2016   \n4     1997-10-07    1.970  234.960            Valente et al., 2016   \n...          ...      ...      ...                             ...   \n2395  2009-04-17   -4.818  204.713            Valente et al., 2016   \n2396  2009-04-18   -6.526  205.066            Valente et al., 2016   \n2397  2009-04-19   -7.189  205.150            Valente et al., 2016   \n2398  2009-12-13   -0.591  199.962            Valente et al., 2016   \n2399  2009-12-25    9.458  205.608            Valente et al., 2016   \n\n          chl_type  in_situ_chl  NASA_chlor_a  TPCA_chl  chl_ci  chl_ocx  ...  \\\n0     Fluorescence       0.1000        0.1365    0.1371  0.1344   0.1149  ...   \n1     Fluorescence       0.0815        0.0653    0.0635  0.0541   0.0443  ...   \n2     Fluorescence       0.0400        0.0578    0.0621  0.0469   0.0811  ...   \n3     Fluorescence       0.0450        0.0614    0.0659  0.0506   0.0833  ...   \n4     Fluorescence       0.0610        0.0951    0.0957  0.0856   0.0834  ...   \n...            ...          ...           ...       ...     ...      ...  ...   \n2395  Fluorescence       0.1070        0.0983    0.1094  0.0891   0.1335  ...   \n2396  Fluorescence       0.0560        0.1264    0.1385  0.1200   0.1524  ...   \n2397  Fluorescence       0.1010        0.1365    0.1482  0.1322   0.1557  ...   \n2398  Fluorescence       0.2140        0.2424    0.2486  0.2251   0.2629  ...   \n2399  Fluorescence       0.0350        0.0680    0.0709  0.0571   0.0761  ...   \n\n      rrs510/rrs555  rrs510/rrs670  rrs555/rrs443  rrs555/rrs490  \\\n0               NaN            NaN            NaN            NaN   \n1               NaN            NaN            NaN            NaN   \n2               NaN            NaN            NaN            NaN   \n3               NaN            NaN            NaN            NaN   \n4               NaN            NaN            NaN            NaN   \n...             ...            ...            ...            ...   \n2395            NaN            NaN            NaN            NaN   \n2396            NaN            NaN            NaN            NaN   \n2397            NaN            NaN            NaN            NaN   \n2398            NaN            NaN            NaN            NaN   \n2399            NaN            NaN            NaN            NaN   \n\n      rrs555/rrs510  rrs555/rrs670  rrs670/rrs443  rrs670/rrs490  \\\n0               NaN            NaN            NaN            NaN   \n1               NaN            NaN            NaN            NaN   \n2               NaN            NaN            NaN            NaN   \n3               NaN            NaN            NaN            NaN   \n4               NaN            NaN            NaN            NaN   \n...             ...            ...            ...            ...   \n2395            NaN            NaN            NaN            NaN   \n2396            NaN            NaN            NaN            NaN   \n2397            NaN            NaN            NaN            NaN   \n2398            NaN            NaN            NaN            NaN   \n2399            NaN            NaN            NaN            NaN   \n\n      rrs670/rrs510  rrs670/rrs555  \n0               NaN            NaN  \n1               NaN            NaN  \n2               NaN            NaN  \n3               NaN            NaN  \n4               NaN            NaN  \n...             ...            ...  \n2395            NaN            NaN  \n2396            NaN            NaN  \n2397            NaN            NaN  \n2398            NaN            NaN  \n2399            NaN            NaN  \n\n[2400 rows x 49 columns]",
      "text/html": "<div>\n<style scoped>\n    .dataframe tbody tr th:only-of-type {\n        vertical-align: middle;\n    }\n\n    .dataframe tbody tr th {\n        vertical-align: top;\n    }\n\n    .dataframe thead th {\n        text-align: right;\n    }\n</style>\n<table border=\"1\" class=\"dataframe\">\n  <thead>\n    <tr style=\"text-align: right;\">\n      <th></th>\n      <th>obs_date</th>\n      <th>obs_lat</th>\n      <th>obs_lon</th>\n      <th>obs_source</th>\n      <th>chl_type</th>\n      <th>in_situ_chl</th>\n      <th>NASA_chlor_a</th>\n      <th>TPCA_chl</th>\n      <th>chl_ci</th>\n      <th>chl_ocx</th>\n      <th>...</th>\n      <th>rrs510/rrs555</th>\n      <th>rrs510/rrs670</th>\n      <th>rrs555/rrs443</th>\n      <th>rrs555/rrs490</th>\n      <th>rrs555/rrs510</th>\n      <th>rrs555/rrs670</th>\n      <th>rrs670/rrs443</th>\n      <th>rrs670/rrs490</th>\n      <th>rrs670/rrs510</th>\n      <th>rrs670/rrs555</th>\n    </tr>\n  </thead>\n  <tbody>\n    <tr>\n      <th>0</th>\n      <td>1997-10-04</td>\n      <td>9.950</td>\n      <td>234.590</td>\n      <td>MBARI: Strutton &amp; Chavez. 2008</td>\n      <td>Fluorescence</td>\n      <td>0.1000</td>\n      <td>0.1365</td>\n      <td>0.1371</td>\n      <td>0.1344</td>\n      <td>0.1149</td>\n      <td>...</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n    </tr>\n    <tr>\n      <th>1</th>\n      <td>1997-10-05</td>\n      <td>5.990</td>\n      <td>235.070</td>\n      <td>Valente et al., 2016</td>\n      <td>Fluorescence</td>\n      <td>0.0815</td>\n      <td>0.0653</td>\n      <td>0.0635</td>\n      <td>0.0541</td>\n      <td>0.0443</td>\n      <td>...</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n    </tr>\n    <tr>\n      <th>2</th>\n      <td>1997-10-06</td>\n      <td>5.170</td>\n      <td>235.170</td>\n      <td>MBARI: Strutton &amp; Chavez. 2008</td>\n      <td>Fluorescence</td>\n      <td>0.0400</td>\n      <td>0.0578</td>\n      <td>0.0621</td>\n      <td>0.0469</td>\n      <td>0.0811</td>\n      <td>...</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n    </tr>\n    <tr>\n      <th>3</th>\n      <td>1997-10-07</td>\n      <td>3.997</td>\n      <td>235.072</td>\n      <td>Valente et al., 2016</td>\n      <td>Fluorescence</td>\n      <td>0.0450</td>\n      <td>0.0614</td>\n      <td>0.0659</td>\n      <td>0.0506</td>\n      <td>0.0833</td>\n      <td>...</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n    </tr>\n    <tr>\n      <th>4</th>\n      <td>1997-10-07</td>\n      <td>1.970</td>\n      <td>234.960</td>\n      <td>Valente et al., 2016</td>\n      <td>Fluorescence</td>\n      <td>0.0610</td>\n      <td>0.0951</td>\n      <td>0.0957</td>\n      <td>0.0856</td>\n      <td>0.0834</td>\n      <td>...</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n    </tr>\n    <tr>\n      <th>...</th>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n      <td>...</td>\n    </tr>\n    <tr>\n      <th>2395</th>\n      <td>2009-04-17</td>\n      <td>-4.818</td>\n      <td>204.713</td>\n      <td>Valente et al., 2016</td>\n      <td>Fluorescence</td>\n      <td>0.1070</td>\n      <td>0.0983</td>\n      <td>0.1094</td>\n      <td>0.0891</td>\n      <td>0.1335</td>\n      <td>...</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n    </tr>\n    <tr>\n      <th>2396</th>\n      <td>2009-04-18</td>\n      <td>-6.526</td>\n      <td>205.066</td>\n      <td>Valente et al., 2016</td>\n      <td>Fluorescence</td>\n      <td>0.0560</td>\n      <td>0.1264</td>\n      <td>0.1385</td>\n      <td>0.1200</td>\n      <td>0.1524</td>\n      <td>...</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n    </tr>\n    <tr>\n      <th>2397</th>\n      <td>2009-04-19</td>\n      <td>-7.189</td>\n      <td>205.150</td>\n      <td>Valente et al., 2016</td>\n      <td>Fluorescence</td>\n      <td>0.1010</td>\n      <td>0.1365</td>\n      <td>0.1482</td>\n      <td>0.1322</td>\n      <td>0.1557</td>\n      <td>...</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n    </tr>\n    <tr>\n      <th>2398</th>\n      <td>2009-12-13</td>\n      <td>-0.591</td>\n      <td>199.962</td>\n      <td>Valente et al., 2016</td>\n      <td>Fluorescence</td>\n      <td>0.2140</td>\n      <td>0.2424</td>\n      <td>0.2486</td>\n      <td>0.2251</td>\n      <td>0.2629</td>\n      <td>...</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n    </tr>\n    <tr>\n      <th>2399</th>\n      <td>2009-12-25</td>\n      <td>9.458</td>\n      <td>205.608</td>\n      <td>Valente et al., 2016</td>\n      <td>Fluorescence</td>\n      <td>0.0350</td>\n      <td>0.0680</td>\n      <td>0.0709</td>\n      <td>0.0571</td>\n      <td>0.0761</td>\n      <td>...</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n      <td>NaN</td>\n    </tr>\n  </tbody>\n</table>\n<p>2400 rows × 49 columns</p>\n</div>"
     },
     "metadata": {},
     "output_type": "execute_result",
     "execution_count": 63
    }
   ],
   "source": [
    "commonCols = ['rrs412','rrs443','rrs490','rrs510','rrs555','rrs670']\n",
    "\n",
    "# cols412 = ['rrs412/rrs443','rrs412/rrs490','rrs412/rrs510','rrs412/rrs555','rrs412/rrs670']\n",
    "cols412 = []\n",
    "cols443 = ['rrs443/rrs490','rrs443/rrs510','rrs443/rrs555','rrs443/rrs670']\n",
    "cols490 = ['rrs490/rrs443','rrs490/rrs510','rrs490/rrs555','rrs490/rrs670']\n",
    "cols510 = ['rrs510/rrs443','rrs510/rrs490','rrs510/rrs555','rrs510/rrs670']\n",
    "cols555 = ['rrs555/rrs443','rrs555/rrs490','rrs555/rrs510','rrs555/rrs670']\n",
    "cols670 = ['rrs670/rrs443','rrs670/rrs490','rrs670/rrs510','rrs670/rrs555']\n",
    "\n",
    "labelCol = ['in_situ_chl','NASA_chlor_a']\n",
    "\n",
    "cols412.extend(cols443)\n",
    "cols412.extend(cols490)\n",
    "cols412.extend(cols510)\n",
    "cols412.extend(cols555)\n",
    "cols412.extend(cols670)\n",
    "\n",
    "\n",
    "\n",
    "col_name = dt.columns.tolist()\n",
    "\n",
    "col_name.extend(cols412)\n",
    "\n",
    "print(commonCols)\n",
    "dt.reindex(columns=col_name)"
   ],
   "metadata": {
    "collapsed": false,
    "pycharm": {
     "name": "#%%\n",
     "is_executing": false
    }
   }
  },
  {
   "cell_type": "markdown",
   "source": [
    "### 412 波段比"
   ],
   "metadata": {
    "collapsed": false
   }
  },
  {
   "cell_type": "code",
   "execution_count": 64,
   "outputs": [],
   "source": [
    "#dt['rrs412/rrs443'] = dt['seawifs_rrs412']/dt['seawifs_rrs443']\n",
    "#dt['rrs412/rrs490'] = dt['seawifs_rrs412']/dt['seawifs_rrs490']\n",
    "#dt['rrs412/rrs510'] = dt['seawifs_rrs412']/dt['seawifs_rrs510']\n",
    "#dt['rrs412/rrs555'] = dt['seawifs_rrs412']/dt['seawifs_rrs555']\n",
    "#dt['rrs412/rrs670'] = dt['seawifs_rrs412']/dt['seawifs_rrs670']\n"
   ],
   "metadata": {
    "collapsed": false,
    "pycharm": {
     "name": "#%%\n",
     "is_executing": false
    }
   }
  },
  {
   "cell_type": "markdown",
   "source": [
    "### 443 波段比"
   ],
   "metadata": {
    "collapsed": false
   }
  },
  {
   "cell_type": "code",
   "execution_count": 65,
   "outputs": [],
   "source": [
    "#dt['rrs443/rrs412'] = dt['rrs443']/dt['seawifs_rrs412']\n",
    "dt['rrs443/rrs490'] = dt['rrs443']/dt['rrs490']\n",
    "dt['rrs443/rrs510'] = dt['rrs443']/dt['rrs510']\n",
    "dt['rrs443/rrs555'] = dt['rrs443']/dt['rrs555']\n",
    "dt['rrs443/rrs670'] = dt['rrs443']/dt['rrs670']\n"
   ],
   "metadata": {
    "collapsed": false,
    "pycharm": {
     "name": "#%%\n",
     "is_executing": false
    }
   }
  },
  {
   "cell_type": "markdown",
   "source": [
    "### 490 波段比"
   ],
   "metadata": {
    "collapsed": false
   }
  },
  {
   "cell_type": "code",
   "execution_count": 66,
   "outputs": [],
   "source": [
    "#dt['rrs490/rrs412'] = dt['seawifs_rrs490']/dt['seawifs_rrs412']\n",
    "dt['rrs490/rrs443'] = dt['rrs490']/dt['rrs443']\n",
    "dt['rrs490/rrs510'] = dt['rrs490']/dt['rrs510']\n",
    "dt['rrs490/rrs555'] = dt['rrs490']/dt['rrs555']\n",
    "dt['rrs490/rrs670'] = dt['rrs490']/dt['rrs670']\n"
   ],
   "metadata": {
    "collapsed": false,
    "pycharm": {
     "name": "#%%\n",
     "is_executing": false
    }
   }
  },
  {
   "cell_type": "markdown",
   "source": [
    "### 510 波段比"
   ],
   "metadata": {
    "collapsed": false
   }
  },
  {
   "cell_type": "code",
   "execution_count": 67,
   "outputs": [],
   "source": [
    "#dt['rrs510/rrs412'] = dt['seawifs_rrs510']/dt['seawifs_rrs412']\n",
    "dt['rrs510/rrs443'] = dt['rrs510']/dt['rrs443']\n",
    "dt['rrs510/rrs490'] = dt['rrs510']/dt['rrs490']\n",
    "dt['rrs510/rrs555'] = dt['rrs510']/dt['rrs555']\n",
    "dt['rrs510/rrs670'] = dt['rrs510']/dt['rrs670']"
   ],
   "metadata": {
    "collapsed": false,
    "pycharm": {
     "name": "#%%\n",
     "is_executing": false
    }
   }
  },
  {
   "cell_type": "markdown",
   "source": [
    "### 555 波段比"
   ],
   "metadata": {
    "collapsed": false
   }
  },
  {
   "cell_type": "code",
   "execution_count": 68,
   "outputs": [],
   "source": [
    "#dt['rrs555/rrs412'] = dt['seawifs_rrs555']/dt['seawifs_rrs412']\n",
    "dt['rrs555/rrs443'] = dt['rrs555']/dt['rrs443']\n",
    "dt['rrs555/rrs490'] = dt['rrs555']/dt['rrs490']\n",
    "dt['rrs555/rrs510'] = dt['rrs555']/dt['rrs510']\n",
    "dt['rrs555/rrs670'] = dt['rrs555']/dt['rrs670']"
   ],
   "metadata": {
    "collapsed": false,
    "pycharm": {
     "name": "#%%\n",
     "is_executing": false
    }
   }
  },
  {
   "cell_type": "markdown",
   "source": [
    "### 670 波段比"
   ],
   "metadata": {
    "collapsed": false
   }
  },
  {
   "cell_type": "code",
   "execution_count": 69,
   "outputs": [],
   "source": [
    "#dt['rrs670/rrs412'] = dt['seawifs_rrs670']/dt['seawifs_rrs412']\n",
    "dt['rrs670/rrs443'] = dt['rrs670']/dt['rrs443']\n",
    "dt['rrs670/rrs490'] = dt['rrs670']/dt['rrs490']\n",
    "dt['rrs670/rrs510'] = dt['rrs670']/dt['rrs510']\n",
    "dt['rrs670/rrs555'] = dt['rrs670']/dt['rrs555']\n"
   ],
   "metadata": {
    "collapsed": false,
    "pycharm": {
     "name": "#%%\n",
     "is_executing": false
    }
   }
  },
  {
   "cell_type": "code",
   "execution_count": 70,
   "outputs": [],
   "source": [
    "commonCols.extend(cols412)\n",
    "commonCols.extend(labelCol)\n",
    "\n",
    "trainDs = dt[commonCols]\n",
    "\n"
   ],
   "metadata": {
    "collapsed": false,
    "pycharm": {
     "name": "#%%\n",
     "is_executing": false
    }
   }
  },
  {
   "cell_type": "code",
   "execution_count": 71,
   "outputs": [
    {
     "data": {
      "text/plain": "rrs443           float64\nrrs490           float64\nrrs510           float64\nrrs555           float64\nrrs670           float64\nrrs443/rrs490    float64\nrrs443/rrs510    float64\nrrs443/rrs555    float64\nrrs443/rrs670    float64\nrrs490/rrs443    float64\nrrs490/rrs510    float64\nrrs490/rrs555    float64\nrrs490/rrs670    float64\nrrs510/rrs443    float64\nrrs510/rrs490    float64\nrrs510/rrs555    float64\nrrs510/rrs670    float64\nrrs555/rrs443    float64\nrrs555/rrs490    float64\nrrs555/rrs510    float64\nrrs555/rrs670    float64\nrrs670/rrs443    float64\nrrs670/rrs490    float64\nrrs670/rrs510    float64\nrrs670/rrs555    float64\nin_situ_chl      float64\nNASA_chlor_a     float64\ndtype: object"
     },
     "metadata": {},
     "output_type": "execute_result",
     "execution_count": 71
    },
    {
     "data": {
      "text/plain": "<Figure size 432x288 with 1 Axes>",
      "image/png": "iVBORw0KGgoAAAANSUhEUgAAAXwAAAD8CAYAAAB0IB+mAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAALEgAACxIB0t1+/AAAADh0RVh0U29mdHdhcmUAbWF0cGxvdGxpYiB2ZXJzaW9uMy4xLjMsIGh0dHA6Ly9tYXRwbG90bGliLm9yZy+AADFEAAAbeklEQVR4nO3df4xc51X/8ffZ9biZTdqsS4xExg4x4DjECWTbVRqIxLdJW5ymqmNKIQmKoBBqCb7hK9KwkitQ4oZ+VVMLBZACxUBUCrSJk1bLlgT8BzEqinDltTZua1NLJk2cHSPFNN4g4o29Pw5/zMzu3dk7M8/M3pm5M/fzkqLs7NydfXJjn3nmPOc5j7k7IiLS/wa6PQAREekMBXwRkYxQwBcRyQgFfBGRjFDAFxHJCAV8EZGMaBjwzexJM3vdzL5T43kzsz8xs9Nm9i0ze0/ywxQRkbUKmeF/EbizzvMfBraW/9kN/NnahyUiIklrGPDd/RvA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6F/R/7e3efc/XvAKUpvAP0m5F48ABwEcPd/Ay6j1Fgta4LiSbV2B3y1ZVjW8F6U0xh/TinY92ueFhrcC3d/092vcvdr3f1aSusZO9295aZRKRbyd2Sc0oI+ZnYVpRTPyx0dZWeE3IszwAcAzOzHKQX8cx0dZTpMAL9crta5FXjT3f+z0Q+1NaXj7WvL0HMC78V+4ArgmfK69Rl339m1QbdJ4L3IhMB7cQj4WTM7CSwAY+7+/e6Nuj0C78XDwF+Y2UOUUhif6McJopl9hVIK76ryesWjQA7A3b9Aaf3iLuA0cAH41aDX7cN7JSIiMbTTVkQkIxTwRUQyQgFfRCQjFPBFRDJCAV9EJCMU8EVEMkIBX0QkI/4X/QT1L3UydxkAAAAASUVORK5CYII=\n"
     },
     "metadata": {
      "needs_background": "light"
     },
     "output_type": "display_data"
    }
   ],
   "source": [
    "trainDs.head(10)\n",
    "\n",
    "import matplotlib.pyplot as plt\n",
    "#showDs = trainDs[trainDs['in_situ_chl'] < 100]\n",
    "plt.axis([0, 1, 0, 1])\n",
    "plt.scatter(trainDs.NASA_chlor_a,trainDs.in_situ_chl)\n",
    "trainDs.dtypes"
   ],
   "metadata": {
    "collapsed": false,
    "pycharm": {
     "name": "#%%\n",
     "is_executing": false
    }
   }
  },
  {
   "cell_type": "code",
   "execution_count": 72,
   "outputs": [],
   "source": [
    "trainDs.dtypes\n",
    "trainDs.to_csv(r'E:\\02Projects\\papers\\chl_model\\data\\seawifs\\train_dataset2.csv')"
   ],
   "metadata": {
    "collapsed": false,
    "pycharm": {
     "name": "#%%\n",
     "is_executing": false
    }
   }
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "outputs": [],
   "source": [],
   "metadata": {
    "collapsed": false,
    "pycharm": {
     "name": "#%%\n"
    }
   }
  },
  {
   "cell_type": "markdown",
   "source": [
    "\n"
   ],
   "metadata": {
    "collapsed": false
   }
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 2
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython2",
   "version": "2.7.6"
  },
  "pycharm": {
   "stem_cell": {
    "cell_type": "raw",
    "source": [],
    "metadata": {
     "collapsed": false
    }
   }
  }
 },
 "nbformat": 4,
 "nbformat_minor": 0
}